//
//  SYS_HelpModel.h
//  System_App
//
//  Created by czy001 on 2017/11/27.
//  Copyright © 2017年 czy001. All rights reserved.
//

#import <Foundation/Foundation.h>

@interface SYS_HelpModel : NSObject

+ (CGRect)caculateRectFromString:(NSString *)str withFontOfSize:(float)f withWidth:(float)width;

/*手机号码验证 MODIFIED BY HELENSONG*/
+(BOOL)isValidateMobile:(NSString *)mobile;

//利用正则表达式验证
+(BOOL)isValidateEmail:(NSString *)email;

//计算当前标签显示高度
+ (float)caculateTagHeight:(NSString *)str withWidth:(float)width;

//根据字体大小，行间距,宽度来判断label高度
+ (float)caculateLabelHeight:(NSString *)str withFontLimit:(float)font withLineSpace:(float)space withWidth:(float)width;

//转化带小时时间
+ (NSString *)stringFromDateWithHours:(NSDate *)date;

//显示标准时间
+ (NSString *)timestampTransformedIntoStandardTime333:(long long int)time;

//nsdate转nsstring
+ (NSString *)stringFromDate:(NSDate *)date;

//时间戳转nsdate
+ (NSDate *)convertTimeToDate:(long long int)time;

//显示标准时间
+ (NSString *)timestampTransformedIntoStandardTime:(long long int)time;

//显示标准时间   年
+ (NSString *)timestampTransformedIntoStandardTimeYear:(long long int)time;

//显示标准时间   年 时 分
+ (NSString *)timestampTransformedIntoStandardTimeHours:(long long int)time;

//显示标准时间
+ (NSString *)timestampTransformedIntoStandardTime1:(long long int)time;

//显示时间差 如几天前
+ (NSString *)timestampTransformedIntervalTime:(long long int)time;
//显示标准时间    时
+ (NSString *)timestampTransformedIntoStandardTimeHours222:(long long int)time;

//根据颜色制作image
+ (UIImage *)createImageWithColor:(UIColor *)color;

//字符串转时间戳
+ (NSString *)convertToTimeOnlineOrder:(NSString *)time;

//计算年龄
+ (NSString *)caculateTheAgeWithTime:(long long int)time;



//判断是否为固话
+ (BOOL)checkNumber:(NSString *)number;

/**
 *    @brief    验证固定电话区号是否正确（e.g. 010正确，030错误）
 *
 *    @return    返回固定电话区号是否正确
 */
- (BOOL)isAreaCode;

//判断字符长度
+  (int)convertToInt:(NSString*)strtemp;

//将yyyy-MM-dd HH:mm:ss格式时间转换成时间戳
+(long)changeTimeToTimeSp:(NSString *)timeStr;

//将yyyy格式时间转换成时间戳
+(long )changeTimeToTimeSp1:(NSString *)timeStr;

//字符串转时间戳
+ (NSString *)convertToTime:(NSString *)time;

//显示标准时间
+ (NSString *)timestampTransformedIntoStandardTime11:(long long int)time;
//规避null数据
+ (NSString *)checkData:(id)str;

//判断密码是否由6~20位字母数字组成
+(BOOL)checkPassWord:(NSString *)pwd;

//利用正则表达式验证车牌号
+(BOOL)isValidateCarNumber:(NSString *)number;

+ (NSString *)getChineseStringWithString:(NSString *)string;

//json字符串解析
+ (NSDictionary *)dictionaryWithJsonString:(NSString *)jsonString;

+ (NSString *)timestampTransformedIntoStandardTimeYear1:(long long int)time;

+ (NSString*)weekdayStringFromDate:(NSDate*)inputDate;
//显示标准时间   年 时 分
+ (NSString *)timestampTransformedIntoStandardTimeHours1:(long long int)time;
//显示标准时间
+ (NSString *)timestampTransformedIntoStandardTimeYearPoint:(long long int)time;
//加载原图
+ (NSString *) picConversionOriginal:(NSString *) picUrl andPicRect:(CGRect) frame;

//判断内容是否全部为空格 yes 全部为空格 no 不是
+(BOOL) isEmpty1:(NSString *) str;

//计算截止日期到当前时间的间隔
+ (NSString *)caculateIntervalFromNow:(long long int)value;

+ (UIButton *)createBackButton;

//解决图片旋转问题
+ (UIImage *)fixOrientation:(UIImage *)aImage;


//判断是否为double：
+ (BOOL)isPureDouble:(NSString*)string;

//#pragma mark -得到当前时间
+ (NSDate *)CurrentTime;

//#当前时间和后台返回的时间比较方法，返回一个int类型的数据
+ (int)compareCurrentTimeDay:(NSDate *)oneDay withAnotherDay:(NSDate *)anotherDay;

//比较两个日期的大小  日期格式为2016-08-14 08：46：20
+ (NSInteger)compareDate:(NSString*)aDate withDate:(NSString*)bDate;

//获取当前的时间
+(NSString*)getCurrentTimes;

//*取字符串首字母，返回大写字母*/
+ (NSString *)transformMandarinToLatin:(NSString *)string;

@end
